<?php /* Smarty version 2.6.19, created on 2009-02-22 22:46:13
         compiled from articles/category_list.tpl */ ?>
<?php require_once(SMARTY_CORE_DIR . 'core.load_plugins.php');
smarty_core_load_plugins(array('plugins' => array(array('modifier', 'nl2br', 'articles/category_list.tpl', 25, false),)), $this); ?>
<?php if ($this->_tpl_vars['items']): ?>
	<div class="tabs-titles">
		<ul class="tabs-titles">
			<li class="active"><a href="?q=articles/category/list"><span><?php echo $this->_tpl_vars['lang']['articles']['category']['list']; ?>
</span></a></li>
			<li><a href="?q=articles/category/add"><span><?php echo $this->_tpl_vars['lang']['articles']['category']['add']; ?>
</span></a></li>
		</ul>					
	</div>
	<div class="pages-list">
		<form action="?q=articles/category/list" method="post">
			<table class="content-list" cellpadding="0" cellspacing="0" border="0">
				<?php $_from = $this->_tpl_vars['items']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['key'] => $this->_tpl_vars['item']):
?>
					<?php if (!(1 & $this->_tpl_vars['key'])): ?>
						<tr class="gray">
					<?php else: ?>
						<tr>
					<?php endif; ?>
						<td class="check left"><input type="checkbox" name="cat_id[<?php echo $this->_tpl_vars['item']['id']; ?>
]" class="check"/></td>
						<td class="title">
							<div class="border">
								<h4><a href="?q=articles/category/view&id=<?php echo $this->_tpl_vars['item']['id']; ?>
"><?php echo $this->_tpl_vars['item']['name']; ?>
</a></h4>
							</div>
						</td>
						<td class="right">
							<p><?php echo ((is_array($_tmp=$this->_tpl_vars['item']['descr'])) ? $this->_run_mod_handler('nl2br', true, $_tmp) : smarty_modifier_nl2br($_tmp)); ?>
</p>
							<ul class="post-options">
								<li><a href="#">статей (0)</a></li>
							</ul>
							<ul class="post-nav">
								<li class="up"><a href="?q=articles/article/add&cid=<?php echo $this->_tpl_vars['item']['id']; ?>
">добавить статью</a></li>
								<li class="down"><a href="?q=articles/category/edit&id=<?php echo $this->_tpl_vars['item']['id']; ?>
">редактировать</a></li>
								<li class="del"><a href="?q=articles/category/delete&id=<?php echo $this->_tpl_vars['item']['id']; ?>
">удалить</a></li>
							</ul>
						</td>
					</tr>
				<?php endforeach; endif; unset($_from); ?>
				<tr class="op">
					<td class="check left"><input type="checkbox" class="check" /></td>
					<td class="title" colspan="2">
						<div class="border">
							<input type="submit" value="Удалить отмеченые" name="submit" class="submit"/>
						</div>
					</td>
				</tr>
			</table>
		</form>
	</div>
<?php else: ?>
	<p>На данный момент нет ни одной категории. <span><a href="?q=articles/category/add">добавить</a></span></p>
<?php endif; ?>